home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Mac Game Programming Gurus / TricksOfTheMacGameProgrammingGurus.iso / More Source / C⁄C++ / Tetris Light 1.0 / source / resources.h < prev    next >
C/C++ Source or Header  |  1993-07-18  |  5KB  |  197 lines

  1. /**********************************************************************\
  2.  
  3. File:        resources.c
  4.  
  5. Purpose:    This header file contains definition of resource ID numbers.
  6.             
  7.  
  8. ``Tetris Light'' - a simple implementation of a Tetris game.
  9. Copyright (C) 1993 Hoylen Sue
  10.  
  11. This program is free software; you can redistribute it and/or modify
  12. it under the terms of the GNU General Public License as published by
  13. the Free Software Foundation; either version 2 of the License, or
  14. (at your option) any later version.
  15.  
  16. This program is distributed in the hope that it will be useful,
  17. but WITHOUT ANY WARRANTY; without even the implied warranty of
  18. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  19. GNU General Public License for more details.
  20.  
  21. You should have received a copy of the GNU General Public License
  22. along with this program; see the file COPYING.  If not, write to the
  23. Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
  24.  
  25. \**********************************************************************/
  26.  
  27. #ifndef resources_H
  28. #define resources_H
  29.  
  30. /*--------------------------------------------------------------------*/
  31.  
  32. /* File types and application signatures.  These have been registered
  33.    with Apple for use with this application. */
  34.  
  35. #define CREATOR_SIGNATURE    'TetL'
  36. #define SAVE_FILE_SIGNATURE    'TLsv'
  37. #define PREF_FILE_SIGNATURE 'pref'
  38.  
  39. /*--------------------------------------------------------------------*/
  40.  
  41. /* Resources for saving preferences and high scores */
  42.  
  43. #define PREF_RSRC_TYPE            'PREF'
  44.  
  45. #define KEYS_PREF_ID            7000
  46. #define GAME_WPOS_PREF_ID        7001
  47. #define HI_WPOS_PREF_ID            7002
  48.  
  49. #define HIGH_SCORE_BASE_PREF_ID    8000
  50.  
  51. /*--------------------------------------------------------------------*/
  52.  
  53. #define PATTERN_ID            0
  54.  
  55. #define KEY_ICON_ID            7000
  56. #define KEY_PRESSED_ICON_ID    7001
  57.  
  58. /*--------------------------------------------------------------------*/
  59.  
  60. /* SND resources */
  61.  
  62. #define HIT_SND_ID            7000
  63. #define END_SND_ID            7001
  64.  
  65. /*--------------------------------------------------------------------*/
  66.  
  67. /* MENU resource IDs */
  68.  
  69. #define MBAR_ID            7000
  70.  
  71. #define APPLE_MENU_ID    7000
  72. #define FILE_MENU_ID    7001
  73. #define EDIT_MENU_ID    7002
  74. #define OPTIONS_MENU_ID    7003
  75.  
  76. /*--------------------------------------------------------------------*/
  77.  
  78. /* Apple Menu Items */
  79.  
  80. #define APPLE_MITEM_ABOUT    1
  81.  
  82.  
  83. /* File Menu Items */
  84.  
  85. #define FILE_MITEM_NEW        1
  86. #define FILE_MITEM_OPEN        2
  87.  
  88. #define FILE_MITEM_SAVE        4
  89. #define FILE_MITEM_SAVE_AS    5
  90.  
  91. #define FILE_MITEM_QUIT        7
  92.  
  93.  
  94. /* Edit Menu Items */
  95.  
  96. #define EDIT_MITEM_UNDO        1
  97.  
  98. #define EDIT_MITEM_CUT        3
  99. #define EDIT_MITEM_COPY        4
  100. #define EDIT_MITEM_PASTE    5
  101. #define EDIT_MITEM_CLEAR    6
  102.  
  103. #define EDIT_MITEM_KEYS        8
  104.  
  105.  
  106. /* Options Menu Items */
  107.  
  108. #define OPTIONS_MITEM_SHOWHIGH    1
  109.     
  110. #define OPTIONS_MITEM_SOUND        3
  111. #define OPTIONS_MITEM_NEXTPIECE    4
  112.  
  113. /*--------------------------------------------------------------------*/
  114.  
  115. /* CNTL resource templates */
  116.  
  117. #define GAME_PAUSE_CNTL_ID    7000
  118. #define HIGH_OK_CNTL_ID        7001
  119.  
  120. /*--------------------------------------------------------------------*/
  121.  
  122. /* STR resources */
  123.  
  124. #define PREF_FILE_STR_ID    7000
  125. #define SCORE_STR_ID        7001
  126. #define GAME_OVER_STR_ID    7002
  127. #define PAUSE_STR_ID        7003
  128. #define CONTINUE_STR_ID        7004
  129.  
  130. /*--------------------------------------------------------------------*/
  131.  
  132. /* STR# resources */
  133.  
  134. #define FATAL_ALERT_STRs_ID            7000
  135. #define CAUTION_ALERT_STRs_ID        7001
  136. #define CAUTION_ERC_ALERT_STRs_ID    7002
  137.  
  138. /*--------------------------------------------------------------------*/
  139.  
  140. /* WIND resources */
  141.  
  142. #define GAME_WINDOW_ID        7000
  143. #define HIGHSCORE_WINDOW_ID    7001
  144.  
  145. /*--------------------------------------------------------------------*/
  146.  
  147. /* Dialog resources */
  148.  
  149. #define FATAL_DIAL_ID        6000
  150. #define CAUTION_DIAL_ID        6001
  151. #define CAUTION_ERC_DIAL_ID    6002
  152.  
  153. #define GET_NAME_DIAL_ID    7000
  154. #define ABOUT_DIAL_ID        7002
  155. #define KEY_DIAL_ID            7003
  156.  
  157. /*--------------------------------------------------------------------*/
  158.  
  159. /* Fatal dialog items */
  160.  
  161. #define FATAL_DIAL_HIGHLIGHT_ITEM    2
  162. #define FATAL_DIAL_TEXT_ITEM        3
  163.  
  164. /* Caution dialog items */
  165.  
  166. #define CAUTION_DIAL_HIGHLIGHT_ITEM    2
  167. #define CAUTION_DIAL_TEXT_ITEM        3
  168.  
  169. /* Caution erc dialog item numbers */
  170.  
  171. #define CAUTION_ERC_DIAL_HIGHLIGHT_ITEM    2
  172. #define CAUTION_ERC_DIAL_TEXT_ITEM        3
  173. #define CAUTION_ERC_ERC_ITEM_NO            4
  174.  
  175. /* Items for GET_NAME_DIAL */
  176.  
  177. #define NAME_ITEM_NO            3
  178. #define NAME_HIGHLIGHT_ITEM_NO    5
  179.  
  180. /* About dialog items */
  181.  
  182. #define ABOUT_HIGHLIGHT_ITEM    2
  183.  
  184. /* Keys dialog items */
  185.  
  186. #define KEYS_ITEM_OK            1
  187. #define KEYS_ITEM_CANCEL        2
  188. #define KEYS_ITEM_HIGHLIGHT        3
  189. #define KEYS_ITEM_LEFT_KEY        4
  190. #define KEYS_ITEM_ROT_KEY        5
  191. #define KEYS_ITEM_RIGHT_KEY        6
  192. #define KEYS_ITEM_DROP_KEY        7
  193.  
  194. /*--------------------------------------------------------------------*/
  195.  
  196. #endif
  197.